From 4bbf7eafc8e3fc89fc6b9ac215043d150e22c2a5 Mon Sep 17 00:00:00 2001 From: Alastair Tse Date: Thu, 19 Oct 2006 17:46:08 +0100 Subject: [PATCH] [XM] Fix TypeError in exception handler if there is no res_label. Signed-off-by: Alastair Tse --- tools/python/xen/xm/create.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tools/python/xen/xm/create.py b/tools/python/xen/xm/create.py index e6e60dc4a6..7b43ee79da 100644 --- a/tools/python/xen/xm/create.py +++ b/tools/python/xen/xm/create.py @@ -1146,8 +1146,11 @@ def config_security_check(config, verbose): except security.ACMError: print " %s: DENIED" % (resource) (res_label, res_policy) = security.get_res_label(resource) - print " --> res:"+res_label+" ("+res_policy+")" - print " --> dom:"+domain_label+" ("+domain_policy+")" + print " --> res: %s (%s)" % (str(res_label), + str(res_policy)) + print " --> dom: %s (%s)" % (str(domain_label), + str(domain_policy)) + answer = 0 return answer -- 2.30.2